"""
api_params_def.py
"""
from dataclasses import dataclass
from datetime import datetime
from typing import List
import numpy as np


@dataclass
class ConfigInfo:
    conf_threshold: float
    plot_result: bool


@dataclass
class DetectInputParams:
    # 请求时间
    timestamp: datetime
    # 图片信息
    image_base64: str


@dataclass
class DetectOutputParams:
    error_code: int
    error_msg: str
    timestamp: datetime
    predict_ms: int
    score: float
    detect_code: str
    detect_vertices: np.ndarray
    result_base64: str



